<extend name="Public/frame"/>
<block name="page_body">

    <include file="Public/header"/>

    <div class="layout-container">
        <include file="menu" />
        <div class="box-body">

            <div class="page-container">
                <div class="head">
                    <h1>我的文档</h1>
                </div>
                <div class="body">
                    <if condition="empty($data_list)">
                        <div class="well well-sm">
                            暂无内容
                        </div>
                    <else />
                        <div id="document-blocks">
                            <foreach name="data_list" item="i">
                                <div class="block">
                                    <div class="warp">
                                        <a class="delete command-ajax-delete btn btn-danger btn-xs" href="#" data-href="{:U('Document/post_handle?action=delete&id='.$i['id'])}">
                                            <span class="glyphicon glyphicon-remove"></span>
                                        </a>
                                        <a class="edit btn btn-info btn-xs" href="{:U('Document/post?action=edit&id='.$i['id'])}">
                                            <span class="glyphicon glyphicon-pencil"></span>
                                            修改
                                        </a>
                                        <div class="title">{$i.title|htmlspecialchars}</div>
                                        <div class="operation">
                                            <a class="btn btn-default btn-xs" href="http://{$Think.const.HTTP_HOST}/doc/{$i.out_id}:preview" target="_blank">预览</a>
                                            <a class="btn btn-default btn-xs" href="http://{$Think.const.HTTP_HOST}/doc/download/out_id/{$i.out_id}" target="_blank">Html下载</a>
                                            <a class="btn btn-default btn-xs" href="http://{$Think.const.HTTP_HOST}/doc/{$i.out_id}:print" target="_blank">生成PDF</a>
                                        </div>
                                    </div>
                                </div>
                            </foreach>
                        </div>
                    </if>
                </div>
            </div>

        </div>
    </div>


    <include file="Public/footer"/>

</block>